.class public Les/ij;
.super Les/lj;
.source "ESHttpServer.java"


# annotations
.annotation build Landroid/annotation/SuppressLint;
    value = {
        "NewApi"
    }
.end annotation

.annotation system Ldalvik/annotation/MemberClasses;
    value = {
        Les/ij$a;
    }
.end annotation


# static fields
.field private static t:Les/ij;

.field private static u:Ljava/lang/Object;


# instance fields
.field private q:Ljava/lang/String;

.field private r:Ljava/lang/String;

.field private s:[Ljava/lang/String;


# direct methods
.method static constructor <clinit>()V
    .locals 1

    .line 1
    new-instance v0, Ljava/lang/Object;

    invoke-direct {v0}, Ljava/lang/Object;-><init>()V

    sput-object v0, Les/ij;->u:Ljava/lang/Object;

    return-void
.end method

.method public constructor <init>(Ljava/lang/String;IZ)V
    .locals 2
    .annotation system Ldalvik/annotation/Throws;
        value = {
            Ljava/io/IOException;
        }
    .end annotation

    .line 1
    invoke-direct {p0, p2}, Les/lj;-><init>(I)V

    const-string p2, "ESHttpServer"

    .line 2
    iput-object p2, p0, Les/ij;->q:Ljava/lang/String;

    const/16 p2, 0xd

    new-array p2, p2, [Ljava/lang/String;

    const/4 v0, 0x0

    const-string v1, ".srt"

    aput-object v1, p2, v0

    const/4 v0, 0x1

    const-string v1, ".ass"

    aput-object v1, p2, v0

    const/4 v0, 0x2

    const-string v1, ".ssa"

    aput-object v1, p2, v0

    const/4 v0, 0x3

    const-string v1, ".smi"

    aput-object v1, p2, v0

    const/4 v0, 0x4

    const-string v1, ".psb"

    aput-object v1, p2, v0

    const/4 v0, 0x5

    const-string v1, ".pjs"

    aput-object v1, p2, v0

    const/4 v0, 0x6

    const-string v1, ".stl"

    aput-object v1, p2, v0

    const/4 v0, 0x7

    const-string v1, ".vsf"

    aput-object v1, p2, v0

    const/16 v0, 0x8

    const-string v1, ".zeg"

    aput-object v1, p2, v0

    const/16 v0, 0x9

    const-string v1, ".sub"

    aput-object v1, p2, v0

    const/16 v0, 0xa

    const-string v1, ".idx"

    aput-object v1, p2, v0

    const/16 v0, 0xb

    const-string v1, ".sst"

    aput-object v1, p2, v0

    const/16 v0, 0xc

    const-string v1, ".son"

    aput-object v1, p2, v0

    .line 3
    iput-object p2, p0, Les/ij;->s:[Ljava/lang/String;

    .line 4
    iput-object p1, p0, Les/ij;->r:Ljava/lang/String;

    .line 5
    iput-boolean p3, p0, Les/lj;->g:Z

    return-void
.end method

.method private a(Ljava/lang/String;JJ)Les/lj$c;
    .locals 34

    move-object/from16 v1, p0

    move-object/from16 v0, p1

    move-wide/from16 v2, p2

    move-wide/from16 v4, p4

    .line 32
    invoke-static/range {p1 .. p1}, Lcom/estrongs/android/util/h0;->U(Ljava/lang/String;)I

    move-result v6

    const-string v7, "500 Internal Server Error"

    const-string v8, "bytes"

    const-string v9, "Accept-Ranges"

    const-string v10, "/"

    const-string v13, "-"

    const-string v14, "bytes "

    const-string v15, "Content-Range"

    const-string v11, "Content-Length"

    const-string v12, "200 OK"

    const-string v0, "206 Partial Content"

    move-object/from16 v16, v7

    const-string v7, "404 Not Found"

    move-object/from16 v18, v8

    const-string v8, ""

    move-object/from16 v19, v9

    const-string v9, "application/octet-stream"

    const-wide/16 v20, 0x0

    move-object/from16 v22, v15

    const-string v15, "text/plain"

    move-object/from16 v23, v10

    const/4 v10, 0x1

    if-ne v6, v10, :cond_7

    .line 33
    :try_start_0
    invoke-static/range {p1 .. p1}, Les/r40;->j(Ljava/lang/String;)Z

    move-result v6
    :try_end_0
    .catch Ljava/lang/Exception; {:try_start_0 .. :try_end_0} :catch_0

    const-string v10, "Not Found"

    if-eqz v6, :cond_2

    .line 34
    :try_start_1
    invoke-static/range {p1 .. p1}, Les/q40;->i(Ljava/lang/String;)Ljava/lang/String;

    move-result-object v6

    move-object/from16 v24, v13

    const/4 v13, 0x0

    .line 35
    invoke-virtual {v1, v6, v13}, Les/ij;->a(Ljava/lang/String;Les/o80;)Ljava/lang/String;

    move-result-object v6

    .line 36
    new-instance v13, Ljcifs/smb/SmbFile;

    invoke-direct {v13, v6}, Ljcifs/smb/SmbFile;-><init>(Ljava/lang/String;)V

    .line 37
    invoke-virtual {v13}, Ljcifs/smb/SmbFile;->exists()Z

    move-result v6

    if-nez v6, :cond_0

    .line 38
    new-instance v0, Les/lj$c;

    invoke-direct {v0, v1, v7, v15, v10}, Les/lj$c;-><init>(Les/lj;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;)V

    return-object v0

    .line 39
    :cond_0
    new-instance v6, Ljcifs/smb/SmbRandomAccessFile;

    const-string v7, "r"

    invoke-direct {v6, v13, v7}, Ljcifs/smb/SmbRandomAccessFile;-><init>(Ljcifs/smb/SmbFile;Ljava/lang/String;)V

    cmp-long v7, v2, v20

    if-eqz v7, :cond_1

    .line 40
    invoke-virtual {v6, v2, v3}, Ljcifs/smb/SmbRandomAccessFile;->seek(J)V

    .line 41
    :cond_1
    new-instance v7, Les/s40;

    invoke-direct {v7, v6, v4, v5}, Les/s40;-><init>(Ljcifs/smb/SmbRandomAccessFile;J)V

    .line 42
    invoke-virtual {v13}, Ljcifs/smb/SmbFile;->length()J

    move-result-wide v25

    goto :goto_0

    :cond_2
    move-object/from16 v24, v13

    .line 43
    invoke-static/range {p1 .. p1}, Les/r40;->k(Ljava/lang/String;)Z

    move-result v6

    if-eqz v6, :cond_6

    .line 44
    invoke-static/range {p1 .. p1}, Les/m40;->a(Ljava/lang/String;)Z

    move-result v6

    if-nez v6, :cond_3

    .line 45
    new-instance v0, Les/lj$c;

    invoke-direct {v0, v1, v7, v15, v10}, Les/lj$c;-><init>(Les/lj;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;)V

    return-object v0

    .line 46
    :cond_3
    invoke-static/range {p1 .. p5}, Les/m40;->a(Ljava/lang/String;JJ)Ljava/io/InputStream;

    move-result-object v7

    .line 47
    invoke-static/range {p1 .. p1}, Les/m40;->e(Ljava/lang/String;)J

    move-result-wide v25

    :goto_0
    move-object v10, v14

    move-wide/from16 v13, v25

    cmp-long v6, v2, v20

    if-nez v6, :cond_4

    .line 48
    new-instance v0, Les/lj$c;

    invoke-direct {v0, v1, v12, v9, v7}, Les/lj$c;-><init>(Les/lj;Ljava/lang/String;Ljava/lang/String;Ljava/io/InputStream;)V

    goto :goto_1

    .line 49
    :cond_4
    new-instance v6, Les/lj$c;

    invoke-direct {v6, v1, v0, v9, v7}, Les/lj$c;-><init>(Les/lj;Ljava/lang/String;Ljava/lang/String;Ljava/io/InputStream;)V

    move-object v0, v6

    :goto_1
    cmp-long v6, v4, v20

    if-nez v6, :cond_5

    sub-long v4, v13, v2

    .line 50
    :cond_5
    new-instance v6, Ljava/lang/StringBuilder;

    invoke-direct {v6}, Ljava/lang/StringBuilder;-><init>()V

    invoke-virtual {v6, v8}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v6, v4, v5}, Ljava/lang/StringBuilder;->append(J)Ljava/lang/StringBuilder;

    invoke-virtual {v6}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v6

    invoke-virtual {v0, v11, v6}, Les/lj$c;->a(Ljava/lang/String;Ljava/lang/String;)V

    .line 51
    new-instance v6, Ljava/lang/StringBuilder;

    invoke-direct {v6}, Ljava/lang/StringBuilder;-><init>()V

    invoke-virtual {v6, v10}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v6, v2, v3}, Ljava/lang/StringBuilder;->append(J)Ljava/lang/StringBuilder;

    move-object/from16 v7, v24

    invoke-virtual {v6, v7}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    add-long/2addr v2, v4

    const-wide/16 v4, 0x1

    sub-long/2addr v2, v4

    invoke-virtual {v6, v2, v3}, Ljava/lang/StringBuilder;->append(J)Ljava/lang/StringBuilder;

    move-object/from16 v2, v23

    invoke-virtual {v6, v2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v6, v13, v14}, Ljava/lang/StringBuilder;->append(J)Ljava/lang/StringBuilder;

    invoke-virtual {v6}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v2

    move-object/from16 v13, v22

    invoke-virtual {v0, v13, v2}, Les/lj$c;->a(Ljava/lang/String;Ljava/lang/String;)V

    move-object/from16 v14, v18

    move-object/from16 v2, v19

    .line 52
    invoke-virtual {v0, v2, v14}, Les/lj$c;->a(Ljava/lang/String;Ljava/lang/String;)V

    return-object v0

    .line 53
    :cond_6
    new-instance v0, Les/lj$c;

    const-string v2, "501 Not Implemented"

    const-string v3, "Not Implemented"

    invoke-direct {v0, v1, v2, v15, v3}, Les/lj$c;-><init>(Les/lj;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;)V
    :try_end_1
    .catch Ljava/lang/Exception; {:try_start_1 .. :try_end_1} :catch_0

    return-object v0

    :catch_0
    move-exception v0

    .line 54
    invoke-virtual {v0}, Ljava/lang/Exception;->printStackTrace()V

    .line 55
    new-instance v2, Les/lj$c;

    invoke-virtual {v0}, Ljava/lang/Exception;->toString()Ljava/lang/String;

    move-result-object v0

    move-object/from16 v3, v16

    invoke-direct {v2, v1, v3, v15, v0}, Les/lj$c;-><init>(Les/lj;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;)V

    return-object v2

    :cond_7
    move-object v10, v14

    move-object/from16 v14, v18

    move-object/from16 v18, v0

    move-object/from16 v32, v16

    move-object/from16 v16, v7

    move-object/from16 v7, v23

    move-object/from16 v23, v19

    move-object/from16 v19, v32

    move-object/from16 v33, v15

    move-object v15, v13

    move-object/from16 v13, v22

    move-object/from16 v22, v33

    const/4 v0, 0x2

    move-object/from16 v24, v14

    const/16 v14, 0x15

    if-eq v6, v0, :cond_15

    const/4 v0, 0x5

    if-eq v6, v0, :cond_15

    if-eq v6, v14, :cond_15

    const/16 v0, 0x16

    if-eq v6, v0, :cond_15

    const/16 v0, 0x13

    if-eq v6, v0, :cond_15

    const/16 v0, 0x14

    if-ne v6, v0, :cond_8

    goto/16 :goto_8

    :cond_8
    const/4 v0, 0x4

    if-eq v6, v0, :cond_11

    const/16 v0, 0x17

    if-ne v6, v0, :cond_9

    goto/16 :goto_5

    :cond_9
    const/4 v0, 0x3

    if-eq v6, v0, :cond_e

    const/16 v0, 0x21

    if-ne v6, v0, :cond_a

    move-object/from16 v6, p1

    move-object v0, v7

    move-object/from16 v7, v18

    move-object/from16 v27, v19

    move-object/from16 v28, v22

    move-object/from16 v19, v23

    move-object/from16 v18, v24

    goto/16 :goto_3

    :cond_a
    const/16 v0, 0x24

    if-ne v6, v0, :cond_d

    .line 56
    :try_start_2
    invoke-static/range {p1 .. p1}, Lcom/estrongs/fs/impl/adb/c;->i(Ljava/lang/String;)Lcom/estrongs/fs/e;

    move-result-object v0

    move-object/from16 v26, v13

    .line 57
    iget-wide v13, v0, Lcom/estrongs/fs/e;->d:J

    .line 58
    invoke-static {}, Lcom/estrongs/fs/f;->d()Lcom/estrongs/fs/f;

    move-result-object v0

    move-object/from16 v6, p1

    move-object/from16 v32, v18

    move-object/from16 v18, v7

    move-object/from16 v7, v32

    invoke-virtual {v0, v6, v2, v3}, Lcom/estrongs/fs/f;->a(Ljava/lang/String;J)Ljava/io/InputStream;

    move-result-object v0

    cmp-long v6, v2, v20

    if-nez v6, :cond_b

    .line 59
    new-instance v6, Les/lj$c;

    invoke-direct {v6, v1, v12, v9, v0}, Les/lj$c;-><init>(Les/lj;Ljava/lang/String;Ljava/lang/String;Ljava/io/InputStream;)V

    goto :goto_2

    .line 60
    :cond_b
    new-instance v6, Les/lj$c;

    invoke-direct {v6, v1, v7, v9, v0}, Les/lj$c;-><init>(Les/lj;Ljava/lang/String;Ljava/lang/String;Ljava/io/InputStream;)V

    :goto_2
    cmp-long v0, v4, v20

    if-nez v0, :cond_c

    sub-long v4, v13, v2

    .line 61
    :cond_c
    new-instance v0, Ljava/lang/StringBuilder;

    invoke-direct {v0}, Ljava/lang/StringBuilder;-><init>()V

    invoke-virtual {v0, v8}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v0, v4, v5}, Ljava/lang/StringBuilder;->append(J)Ljava/lang/StringBuilder;

    invoke-virtual {v0}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v0

    invoke-virtual {v6, v11, v0}, Les/lj$c;->a(Ljava/lang/String;Ljava/lang/String;)V

    .line 62
    new-instance v0, Ljava/lang/StringBuilder;

    invoke-direct {v0}, Ljava/lang/StringBuilder;-><init>()V

    invoke-virtual {v0, v10}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v0, v2, v3}, Ljava/lang/StringBuilder;->append(J)Ljava/lang/StringBuilder;

    invoke-virtual {v0, v15}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    add-long/2addr v2, v4

    const-wide/16 v4, 0x1

    sub-long/2addr v2, v4

    invoke-virtual {v0, v2, v3}, Ljava/lang/StringBuilder;->append(J)Ljava/lang/StringBuilder;

    move-object/from16 v2, v18

    invoke-virtual {v0, v2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v0, v13, v14}, Ljava/lang/StringBuilder;->append(J)Ljava/lang/StringBuilder;

    invoke-virtual {v0}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v0

    move-object/from16 v13, v26

    invoke-virtual {v6, v13, v0}, Les/lj$c;->a(Ljava/lang/String;Ljava/lang/String;)V

    move-object/from16 v14, v23

    move-object/from16 v0, v24

    .line 63
    invoke-virtual {v6, v14, v0}, Les/lj$c;->a(Ljava/lang/String;Ljava/lang/String;)V
    :try_end_2
    .catch Ljava/lang/Exception; {:try_start_2 .. :try_end_2} :catch_1

    return-object v6

    :catch_1
    move-exception v0

    .line 64
    invoke-virtual {v0}, Ljava/lang/Exception;->printStackTrace()V

    .line 65
    new-instance v2, Les/lj$c;

    invoke-virtual {v0}, Ljava/lang/Exception;->toString()Ljava/lang/String;

    move-result-object v0

    move-object/from16 v3, v19

    move-object/from16 v4, v22

    invoke-direct {v2, v1, v3, v4, v0}, Les/lj$c;-><init>(Les/lj;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;)V

    return-object v2

    :cond_d
    move-object/from16 v4, v22

    .line 66
    new-instance v0, Les/lj$c;

    const-string v2, "400 Bad Request"

    const-string v3, "Not Supported"

    invoke-direct {v0, v1, v2, v4, v3}, Les/lj$c;-><init>(Les/lj;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;)V

    return-object v0

    :cond_e
    move-object/from16 v6, p1

    move-object v0, v7

    move-object/from16 v7, v18

    move-object/from16 v27, v19

    move-object/from16 v28, v22

    move-object/from16 v18, v24

    move-object/from16 v19, v23

    :goto_3
    const/4 v14, 0x0

    .line 67
    :try_start_3
    invoke-virtual {v1, v6, v14}, Les/ij;->a(Ljava/lang/String;Les/o80;)Ljava/lang/String;

    move-result-object v6

    .line 68
    invoke-static {}, Lcom/estrongs/fs/f;->d()Lcom/estrongs/fs/f;

    move-result-object v14

    move-object/from16 v22, v13

    invoke-virtual {v14, v6}, Lcom/estrongs/fs/f;->f(Ljava/lang/String;)J

    move-result-wide v13

    move-object/from16 v23, v0

    .line 69
    invoke-static {}, Lcom/estrongs/fs/f;->d()Lcom/estrongs/fs/f;

    move-result-object v0

    invoke-virtual {v0, v6, v2, v3}, Lcom/estrongs/fs/f;->a(Ljava/lang/String;J)Ljava/io/InputStream;

    move-result-object v0

    cmp-long v6, v2, v20

    if-nez v6, :cond_f

    .line 70
    new-instance v6, Les/lj$c;

    invoke-direct {v6, v1, v12, v9, v0}, Les/lj$c;-><init>(Les/lj;Ljava/lang/String;Ljava/lang/String;Ljava/io/InputStream;)V

    goto :goto_4

    .line 71
    :cond_f
    new-instance v6, Les/lj$c;

    invoke-direct {v6, v1, v7, v9, v0}, Les/lj$c;-><init>(Les/lj;Ljava/lang/String;Ljava/lang/String;Ljava/io/InputStream;)V

    :goto_4
    cmp-long v0, v4, v20

    if-nez v0, :cond_10

    sub-long v4, v13, v2

    .line 72
    :cond_10
    new-instance v0, Ljava/lang/StringBuilder;

    invoke-direct {v0}, Ljava/lang/StringBuilder;-><init>()V

    invoke-virtual {v0, v8}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v0, v4, v5}, Ljava/lang/StringBuilder;->append(J)Ljava/lang/StringBuilder;

    invoke-virtual {v0}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v0

    invoke-virtual {v6, v11, v0}, Les/lj$c;->a(Ljava/lang/String;Ljava/lang/String;)V

    .line 73
    new-instance v0, Ljava/lang/StringBuilder;

    invoke-direct {v0}, Ljava/lang/StringBuilder;-><init>()V

    invoke-virtual {v0, v10}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v0, v2, v3}, Ljava/lang/StringBuilder;->append(J)Ljava/lang/StringBuilder;

    invoke-virtual {v0, v15}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    add-long/2addr v2, v4

    const-wide/16 v4, 0x1

    sub-long/2addr v2, v4

    invoke-virtual {v0, v2, v3}, Ljava/lang/StringBuilder;->append(J)Ljava/lang/StringBuilder;

    move-object/from16 v2, v23

    invoke-virtual {v0, v2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v0, v13, v14}, Ljava/lang/StringBuilder;->append(J)Ljava/lang/StringBuilder;

    invoke-virtual {v0}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v0

    move-object/from16 v13, v22

    invoke-virtual {v6, v13, v0}, Les/lj$c;->a(Ljava/lang/String;Ljava/lang/String;)V

    move-object/from16 v0, v18

    move-object/from16 v14, v19

    .line 74
    invoke-virtual {v6, v14, v0}, Les/lj$c;->a(Ljava/lang/String;Ljava/lang/String;)V
    :try_end_3
    .catch Ljava/lang/Exception; {:try_start_3 .. :try_end_3} :catch_2

    return-object v6

    :catch_2
    move-exception v0

    .line 75
    invoke-virtual {v0}, Ljava/lang/Exception;->printStackTrace()V

    .line 76
    new-instance v2, Les/lj$c;

    invoke-virtual {v0}, Ljava/lang/Exception;->toString()Ljava/lang/String;

    move-result-object v0

    move-object/from16 v3, v27

    move-object/from16 v4, v28

    invoke-direct {v2, v1, v3, v4, v0}, Les/lj$c;-><init>(Les/lj;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;)V

    return-object v2

    :cond_11
    :goto_5
    move-object/from16 v6, p1

    move-object v0, v7

    move-object/from16 v7, v18

    move-object/from16 v14, v22

    move-object/from16 v19, v23

    move-object/from16 v18, v24

    move-object/from16 v22, v13

    const/4 v13, 0x0

    .line 77
    :try_start_4
    invoke-virtual {v1, v6, v13}, Les/ij;->a(Ljava/lang/String;Les/o80;)Ljava/lang/String;

    move-result-object v6

    move-object/from16 v23, v10

    move-object v13, v11

    .line 78
    invoke-static {v6}, Les/j30;->g(Ljava/lang/String;)J

    move-result-wide v10

    .line 79
    invoke-static {v6, v2, v3}, Les/j30;->b(Ljava/lang/String;J)Ljava/io/InputStream;

    move-result-object v6

    if-nez v6, :cond_12

    .line 80
    new-instance v0, Les/lj$c;
    :try_end_4
    .catch Ljava/lang/Exception; {:try_start_4 .. :try_end_4} :catch_5

    move-object/from16 v2, v16

    :try_start_5
    invoke-direct {v0, v1, v2, v14, v8}, Les/lj$c;-><init>(Les/lj;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;)V
    :try_end_5
    .catch Ljava/lang/Exception; {:try_start_5 .. :try_end_5} :catch_3

    return-object v0

    :catch_3
    move-exception v0

    move-object v13, v2

    goto :goto_7

    :cond_12
    move-object/from16 p1, v13

    move-object/from16 v13, v16

    cmp-long v16, v2, v20

    if-nez v16, :cond_13

    .line 81
    :try_start_6
    new-instance v7, Les/lj$c;

    invoke-direct {v7, v1, v12, v9, v6}, Les/lj$c;-><init>(Les/lj;Ljava/lang/String;Ljava/lang/String;Ljava/io/InputStream;)V

    goto :goto_6

    .line 82
    :cond_13
    new-instance v12, Les/lj$c;

    invoke-direct {v12, v1, v7, v9, v6}, Les/lj$c;-><init>(Les/lj;Ljava/lang/String;Ljava/lang/String;Ljava/io/InputStream;)V

    move-object v7, v12

    :goto_6
    cmp-long v6, v4, v20

    if-nez v6, :cond_14

    sub-long v4, v10, v2

    .line 83
    :cond_14
    new-instance v6, Ljava/lang/StringBuilder;

    invoke-direct {v6}, Ljava/lang/StringBuilder;-><init>()V

    invoke-virtual {v6, v8}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v6, v4, v5}, Ljava/lang/StringBuilder;->append(J)Ljava/lang/StringBuilder;

    invoke-virtual {v6}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v6

    move-object/from16 v8, p1

    invoke-virtual {v7, v8, v6}, Les/lj$c;->a(Ljava/lang/String;Ljava/lang/String;)V

    .line 84
    new-instance v6, Ljava/lang/StringBuilder;

    invoke-direct {v6}, Ljava/lang/StringBuilder;-><init>()V

    move-object/from16 v8, v23

    invoke-virtual {v6, v8}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v6, v2, v3}, Ljava/lang/StringBuilder;->append(J)Ljava/lang/StringBuilder;

    invoke-virtual {v6, v15}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    add-long/2addr v2, v4

    const-wide/16 v4, 0x1

    sub-long/2addr v2, v4

    invoke-virtual {v6, v2, v3}, Ljava/lang/StringBuilder;->append(J)Ljava/lang/StringBuilder;

    invoke-virtual {v6, v0}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v6, v10, v11}, Ljava/lang/StringBuilder;->append(J)Ljava/lang/StringBuilder;

    invoke-virtual {v6}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v0

    move-object/from16 v10, v22

    invoke-virtual {v7, v10, v0}, Les/lj$c;->a(Ljava/lang/String;Ljava/lang/String;)V

    move-object/from16 v11, v18

    move-object/from16 v0, v19

    .line 85
    invoke-virtual {v7, v0, v11}, Les/lj$c;->a(Ljava/lang/String;Ljava/lang/String;)V
    :try_end_6
    .catch Ljava/lang/Exception; {:try_start_6 .. :try_end_6} :catch_4

    return-object v7

    :catch_4
    move-exception v0

    goto :goto_7

    :catch_5
    move-exception v0

    move-object/from16 v13, v16

    .line 86
    :goto_7
    invoke-virtual {v0}, Ljava/lang/Exception;->printStackTrace()V

    .line 87
    new-instance v2, Les/lj$c;

    invoke-virtual {v0}, Ljava/lang/Exception;->toString()Ljava/lang/String;

    move-result-object v0

    invoke-direct {v2, v1, v13, v14, v0}, Les/lj$c;-><init>(Les/lj;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;)V

    return-object v2

    :cond_15
    :goto_8
    move-object v0, v7

    move-object/from16 v30, v10

    move-object/from16 v31, v11

    move-object/from16 v7, v18

    move-object/from16 v14, v22

    move-object/from16 v29, v23

    move-object/from16 v18, v24

    const/16 v10, 0x15

    move-object/from16 v11, p1

    move-object/from16 v22, v13

    move-object/from16 v13, v16

    if-eq v6, v10, :cond_17

    const/16 v10, 0x16

    if-ne v6, v10, :cond_16

    goto :goto_9

    .line 88
    :cond_16
    :try_start_7
    invoke-static/range {p1 .. p1}, Lcom/estrongs/android/util/h0;->f0(Ljava/lang/String;)Ljava/lang/String;

    move-result-object v6

    invoke-static {v6}, Lcom/estrongs/fs/f;->s(Ljava/lang/String;)Les/o80;

    move-result-object v6

    .line 89
    invoke-virtual {v1, v11, v6}, Les/ij;->a(Ljava/lang/String;Les/o80;)Ljava/lang/String;

    move-result-object v10

    .line 90
    invoke-interface {v6, v10}, Les/o80;->h(Ljava/lang/String;)J

    move-result-wide v16

    .line 91
    invoke-interface {v6, v10, v2, v3}, Les/o80;->a(Ljava/lang/String;J)Ljava/io/InputStream;

    move-result-object v6

    goto :goto_a

    :cond_17
    :goto_9
    const/4 v6, 0x0

    .line 92
    invoke-virtual {v1, v11, v6}, Les/ij;->a(Ljava/lang/String;Les/o80;)Ljava/lang/String;

    move-result-object v10

    .line 93
    invoke-static {v10}, Les/p60;->c(Ljava/lang/String;)J

    move-result-wide v16

    .line 94
    invoke-static {v10, v2, v3, v6}, Les/p60;->a(Ljava/lang/String;JLcom/estrongs/android/util/TypedMap;)Ljava/io/InputStream;

    move-result-object v6

    :goto_a
    move-wide/from16 v10, v16

    if-nez v6, :cond_18

    .line 95
    new-instance v0, Les/lj$c;

    invoke-direct {v0, v1, v13, v14, v8}, Les/lj$c;-><init>(Les/lj;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;)V

    return-object v0

    :cond_18
    cmp-long v16, v2, v20

    if-nez v16, :cond_19

    .line 96
    new-instance v7, Les/lj$c;

    invoke-direct {v7, v1, v12, v9, v6}, Les/lj$c;-><init>(Les/lj;Ljava/lang/String;Ljava/lang/String;Ljava/io/InputStream;)V

    goto :goto_b

    .line 97
    :cond_19
    new-instance v12, Les/lj$c;

    invoke-direct {v12, v1, v7, v9, v6}, Les/lj$c;-><init>(Les/lj;Ljava/lang/String;Ljava/lang/String;Ljava/io/InputStream;)V

    move-object v7, v12

    :goto_b
    cmp-long v6, v4, v20

    if-nez v6, :cond_1a

    sub-long v4, v10, v2

    .line 98
    :cond_1a
    new-instance v6, Ljava/lang/StringBuilder;

    invoke-direct {v6}, Ljava/lang/StringBuilder;-><init>()V

    invoke-virtual {v6, v8}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v6, v4, v5}, Ljava/lang/StringBuilder;->append(J)Ljava/lang/StringBuilder;

    invoke-virtual {v6}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v6

    move-object/from16 v8, v31

    invoke-virtual {v7, v8, v6}, Les/lj$c;->a(Ljava/lang/String;Ljava/lang/String;)V

    .line 99
    new-instance v6, Ljava/lang/StringBuilder;

    invoke-direct {v6}, Ljava/lang/StringBuilder;-><init>()V

    move-object/from16 v8, v30

    invoke-virtual {v6, v8}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v6, v2, v3}, Ljava/lang/StringBuilder;->append(J)Ljava/lang/StringBuilder;

    invoke-virtual {v6, v15}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    add-long/2addr v2, v4

    const-wide/16 v4, 0x1

    sub-long/2addr v2, v4

    invoke-virtual {v6, v2, v3}, Ljava/lang/StringBuilder;->append(J)Ljava/lang/StringBuilder;

    invoke-virtual {v6, v0}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v6, v10, v11}, Ljava/lang/StringBuilder;->append(J)Ljava/lang/StringBuilder;

    invoke-virtual {v6}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v0

    move-object/from16 v2, v22

    invoke-virtual {v7, v2, v0}, Les/lj$c;->a(Ljava/lang/String;Ljava/lang/String;)V

    move-object/from16 v0, v18

    move-object/from16 v2, v29

    .line 100
    invoke-virtual {v7, v2, v0}, Les/lj$c;->a(Ljava/lang/String;Ljava/lang/String;)V
    :try_end_7
    .catch Ljava/lang/Exception; {:try_start_7 .. :try_end_7} :catch_6

    return-object v7

    :catch_6
    move-exception v0

    .line 101
    invoke-virtual {v0}, Ljava/lang/Exception;->printStackTrace()V

    .line 102
    new-instance v2, Les/lj$c;

    invoke-virtual {v0}, Ljava/lang/Exception;->toString()Ljava/lang/String;

    move-result-object v0

    invoke-direct {v2, v1, v13, v14, v0}, Les/lj$c;-><init>(Les/lj;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;)V

    return-object v2
.end method

.method public static a(Z)Z
    .locals 8

    .line 1
    sget-object v0, Les/ij;->u:Ljava/lang/Object;

    monitor-enter v0

    .line 2
    :try_start_0
    sget-object v1, Les/ij;->t:Les/ij;

    const/4 v2, 0x1

    if-eqz v1, :cond_0

    sget-object v1, Les/ij;->t:Les/ij;

    invoke-virtual {v1}, Les/ij;->d()Z

    move-result v1

    if-eqz v1, :cond_0

    .line 3
    monitor-exit v0

    return v2

    .line 4
    :cond_0
    sget-object v1, Les/ij;->t:Les/ij;
    :try_end_0
    .catchall {:try_start_0 .. :try_end_0} :catchall_0

    const/4 v3, 0x0

    if-eqz v1, :cond_1

    .line 5
    :try_start_1
    sget-object v1, Les/ij;->t:Les/ij;

    invoke-virtual {v1}, Les/lj;->b()V
    :try_end_1
    .catch Ljava/lang/Exception; {:try_start_1 .. :try_end_1} :catch_0
    .catchall {:try_start_1 .. :try_end_1} :catchall_0

    .line 6
    :catch_0
    :try_start_2
    sput-object v3, Les/ij;->t:Les/ij;
    :try_end_2
    .catchall {:try_start_2 .. :try_end_2} :catchall_0

    :cond_1
    const/4 v1, 0x0

    const/4 v4, 0x0

    :goto_0
    const/4 v5, 0x5

    if-ge v4, v5, :cond_4

    .line 7
    :try_start_3
    new-instance v5, Les/ij;

    const-string v6, "/sdcard"

    const v7, 0xe981

    add-int/2addr v7, v4

    invoke-direct {v5, v6, v7, p0}, Les/ij;-><init>(Ljava/lang/String;IZ)V

    sput-object v5, Les/ij;->t:Les/ij;

    const/16 v5, 0x3e8

    :goto_1
    if-lez v5, :cond_3

    .line 8
    sget-object v6, Les/ij;->t:Les/ij;

    invoke-virtual {v6}, Les/ij;->d()Z

    move-result v6

    if-eqz v6, :cond_2

    goto :goto_2

    :cond_2
    const-wide/16 v6, 0xc8

    .line 9
    invoke-static {v6, v7}, Ljava/lang/Thread;->sleep(J)V
    :try_end_3
    .catch Ljava/lang/Exception; {:try_start_3 .. :try_end_3} :catch_1
    .catchall {:try_start_3 .. :try_end_3} :catchall_0

    add-int/lit16 v5, v5, -0xc8

    goto :goto_1

    :cond_3
    const/4 v2, 0x0

    .line 10
    :goto_2
    :try_start_4
    monitor-exit v0

    return v2

    :catch_1
    move-exception v5

    .line 11
    sput-object v3, Les/ij;->t:Les/ij;

    .line 12
    invoke-virtual {v5}, Ljava/lang/Exception;->printStackTrace()V

    add-int/lit8 v4, v4, 0x1

    goto :goto_0

    .line 13
    :cond_4
    monitor-exit v0

    return v1

    :catchall_0
    move-exception p0

    .line 14
    monitor-exit v0
    :try_end_4
    .catchall {:try_start_4 .. :try_end_4} :catchall_0

    goto :goto_4

    :goto_3
    throw p0

    :goto_4
    goto :goto_3
.end method

.method public static c(Ljava/lang/String;)Ljava/io/InputStream;
    .locals 2

    const/4 v0, 0x0

    if-nez p0, :cond_0

    return-object v0

    .line 1
    :cond_0
    invoke-virtual {p0}, Ljava/lang/String;->trim()Ljava/lang/String;

    move-result-object p0

    const-string v1, ""

    .line 2
    invoke-virtual {p0, v1}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z

    move-result v1

    if-nez v1, :cond_1

    .line 3
    new-instance v0, Ljava/io/ByteArrayInputStream;

    invoke-virtual {p0}, Ljava/lang/String;->getBytes()[B

    move-result-object p0

    invoke-direct {v0, p0}, Ljava/io/ByteArrayInputStream;-><init>([B)V

    :cond_1
    return-object v0
.end method

.method public static f()I
    .locals 2

    .line 1
    sget-object v0, Les/ij;->u:Ljava/lang/Object;

    monitor-enter v0

    .line 2
    :try_start_0
    sget-object v1, Les/ij;->t:Les/ij;

    if-eqz v1, :cond_0

    .line 3
    sget-object v1, Les/ij;->t:Les/ij;

    iget v1, v1, Les/lj;->j:I

    monitor-exit v0

    return v1

    :cond_0
    const/4 v1, 0x0

    .line 4
    monitor-exit v0

    return v1

    :catchall_0
    move-exception v1

    .line 5
    monitor-exit v0
    :try_end_0
    .catchall {:try_start_0 .. :try_end_0} :catchall_0

    throw v1
.end method

.method public static g()Z
    .locals 1

    const/4 v0, 0x0

    .line 1
    invoke-static {v0}, Les/ij;->a(Z)Z

    move-result v0

    return v0
.end method


# virtual methods
.method public a(I)Les/lj$c;
    .locals 10

    const-string v0, "text/plain"

    const-string v1, "\", "

    const/16 v2, 0x2000

    .line 146
    :try_start_0
    invoke-static {v2}, Lcom/estrongs/android/pop/FexApplication;->b(I)Ljava/util/List;

    move-result-object v2

    .line 147
    new-instance v3, Ljava/util/LinkedList;

    invoke-direct {v3}, Ljava/util/LinkedList;-><init>()V

    .line 148
    invoke-interface {v2}, Ljava/util/List;->iterator()Ljava/util/Iterator;

    move-result-object v2

    :cond_0
    :goto_0
    invoke-interface {v2}, Ljava/util/Iterator;->hasNext()Z

    move-result v4

    const/4 v5, 0x1

    if-eqz v4, :cond_6

    invoke-interface {v2}, Ljava/util/Iterator;->next()Ljava/lang/Object;

    move-result-object v4

    check-cast v4, Landroid/content/pm/PackageInfo;

    .line 149
    iget-object v6, v4, Landroid/content/pm/PackageInfo;->applicationInfo:Landroid/content/pm/ApplicationInfo;

    if-nez p1, :cond_2

    .line 150
    iget v7, v6, Landroid/content/pm/ApplicationInfo;->flags:I

    and-int/lit16 v7, v7, 0x80

    if-nez v7, :cond_1

    iget v6, v6, Landroid/content/pm/ApplicationInfo;->flags:I

    and-int/2addr v5, v6

    if-nez v5, :cond_0

    .line 151
    :cond_1
    invoke-virtual {v3, v4}, Ljava/util/LinkedList;->add(Ljava/lang/Object;)Z

    goto :goto_0

    :cond_2
    if-ne p1, v5, :cond_3

    .line 152
    iget v6, v6, Landroid/content/pm/ApplicationInfo;->flags:I

    and-int/2addr v5, v6

    if-lez v5, :cond_0

    .line 153
    invoke-virtual {v3, v4}, Ljava/util/LinkedList;->add(Ljava/lang/Object;)Z

    goto :goto_0

    :cond_3
    const/4 v5, 0x2

    const/high16 v7, 0x40000

    if-ne p1, v5, :cond_4

    .line 154
    iget v5, v6, Landroid/content/pm/ApplicationInfo;->flags:I

    and-int/2addr v5, v7

    if-nez v5, :cond_0

    .line 155
    invoke-virtual {v3, v4}, Ljava/util/LinkedList;->add(Ljava/lang/Object;)Z

    goto :goto_0

    :cond_4
    const/4 v5, 0x3

    if-ne p1, v5, :cond_5

    .line 156
    iget v5, v6, Landroid/content/pm/ApplicationInfo;->flags:I

    and-int/2addr v5, v7

    if-eqz v5, :cond_0

    .line 157
    invoke-virtual {v3, v4}, Ljava/util/LinkedList;->add(Ljava/lang/Object;)Z

    goto :goto_0

    :cond_5
    const/4 v5, 0x4

    if-ne p1, v5, :cond_0

    .line 158
    invoke-virtual {v3, v4}, Ljava/util/LinkedList;->add(Ljava/lang/Object;)Z

    goto :goto_0

    :cond_6
    const-string p1, "[\r\n"

    const/4 v2, 0x0

    .line 159
    :goto_1
    invoke-virtual {v3}, Ljava/util/LinkedList;->size()I

    move-result v4

    if-ge v2, v4, :cond_9

    .line 160
    invoke-virtual {v3, v2}, Ljava/util/LinkedList;->get(I)Ljava/lang/Object;

    move-result-object v4

    check-cast v4, Landroid/content/pm/PackageInfo;

    .line 161
    new-instance v6, Ljava/io/File;

    iget-object v7, v4, Landroid/content/pm/PackageInfo;->applicationInfo:Landroid/content/pm/ApplicationInfo;

    iget-object v7, v7, Landroid/content/pm/ApplicationInfo;->sourceDir:Ljava/lang/String;

    invoke-direct {v6, v7}, Ljava/io/File;-><init>(Ljava/lang/String;)V

    .line 162
    invoke-virtual {v6}, Ljava/io/File;->exists()Z

    move-result v7

    if-nez v7, :cond_7

    const-wide/16 v6, 0x0

    goto :goto_2

    .line 163
    :cond_7
    invoke-virtual {v6}, Ljava/io/File;->length()J

    move-result-wide v6

    .line 164
    :goto_2
    new-instance v8, Ljava/lang/StringBuilder;

    invoke-direct {v8}, Ljava/lang/StringBuilder;-><init>()V

    invoke-virtual {v8, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    const-string p1, "{"

    invoke-virtual {v8, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v8}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object p1

    .line 165
    new-instance v8, Ljava/lang/StringBuilder;

    invoke-direct {v8}, Ljava/lang/StringBuilder;-><init>()V

    invoke-virtual {v8, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    const-string p1, "\"packageName\":\""

    invoke-virtual {v8, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    iget-object p1, v4, Landroid/content/pm/PackageInfo;->packageName:Ljava/lang/String;

    invoke-virtual {v8, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v8, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v8}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object p1

    .line 166
    new-instance v8, Ljava/lang/StringBuilder;

    invoke-direct {v8}, Ljava/lang/StringBuilder;-><init>()V

    invoke-virtual {v8, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    const-string p1, "\"label\":\""

    invoke-virtual {v8, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-static {}, Lcom/estrongs/android/pop/FexApplication;->n()Lcom/estrongs/android/pop/FexApplication;

    move-result-object p1

    invoke-virtual {p1}, Landroid/app/Application;->getPackageManager()Landroid/content/pm/PackageManager;

    move-result-object p1

    iget-object v9, v4, Landroid/content/pm/PackageInfo;->applicationInfo:Landroid/content/pm/ApplicationInfo;

    invoke-static {p1, v9}, Lcom/estrongs/android/pop/utils/k;->a(Landroid/content/pm/PackageManager;Landroid/content/pm/ApplicationInfo;)Ljava/lang/String;

    move-result-object p1

    invoke-virtual {v8, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v8, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v8}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object p1

    .line 167
    new-instance v8, Ljava/lang/StringBuilder;

    invoke-direct {v8}, Ljava/lang/StringBuilder;-><init>()V

    invoke-virtual {v8, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    const-string p1, "\"version\":\""

    invoke-virtual {v8, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    iget-object p1, v4, Landroid/content/pm/PackageInfo;->versionName:Ljava/lang/String;

    invoke-virtual {v8, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v8, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v8}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object p1

    .line 168
    new-instance v8, Ljava/lang/StringBuilder;

    invoke-direct {v8}, Ljava/lang/StringBuilder;-><init>()V

    invoke-virtual {v8, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    const-string p1, "\"versionCode\":\""

    invoke-virtual {v8, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    iget p1, v4, Landroid/content/pm/PackageInfo;->versionCode:I

    invoke-virtual {v8, p1}, Ljava/lang/StringBuilder;->append(I)Ljava/lang/StringBuilder;

    invoke-virtual {v8, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v8}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object p1

    .line 169
    iget-object v8, v4, Landroid/content/pm/PackageInfo;->applicationInfo:Landroid/content/pm/ApplicationInfo;

    iget-object v8, v8, Landroid/content/pm/ApplicationInfo;->sourceDir:Ljava/lang/String;

    .line 170
    new-instance v9, Ljava/lang/StringBuilder;

    invoke-direct {v9}, Ljava/lang/StringBuilder;-><init>()V

    invoke-virtual {v9, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    const-string p1, "\"location\":\""

    invoke-virtual {v9, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v9, v8}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v9, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v9}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object p1

    .line 171
    new-instance v8, Ljava/lang/StringBuilder;

    invoke-direct {v8}, Ljava/lang/StringBuilder;-><init>()V

    invoke-virtual {v8, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    const-string p1, "\"size\":\""

    invoke-virtual {v8, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v8, v6, v7}, Ljava/lang/StringBuilder;->append(J)Ljava/lang/StringBuilder;

    invoke-virtual {v8, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v8}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object p1

    .line 172
    new-instance v6, Ljava/lang/StringBuilder;

    invoke-direct {v6}, Ljava/lang/StringBuilder;-><init>()V

    invoke-virtual {v6, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    const-string p1, "\"status\":\""

    invoke-virtual {v6, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    iget-object p1, v4, Landroid/content/pm/PackageInfo;->applicationInfo:Landroid/content/pm/ApplicationInfo;

    iget-object p1, p1, Landroid/content/pm/ApplicationInfo;->backupAgentName:Ljava/lang/String;

    invoke-virtual {v6, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v6, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v6}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object p1

    .line 173
    new-instance v6, Ljava/lang/StringBuilder;

    invoke-direct {v6}, Ljava/lang/StringBuilder;-><init>()V

    invoke-virtual {v6, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    const-string p1, "\"mTime\":\""

    invoke-virtual {v6, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    iget-wide v7, v4, Landroid/content/pm/PackageInfo;->lastUpdateTime:J

    invoke-virtual {v6, v7, v8}, Ljava/lang/StringBuilder;->append(J)Ljava/lang/StringBuilder;

    const-string p1, "\""

    invoke-virtual {v6, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v6}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object p1

    .line 174
    invoke-virtual {v3}, Ljava/util/LinkedList;->size()I

    move-result v4

    sub-int/2addr v4, v5

    if-ge v2, v4, :cond_8

    .line 175
    new-instance v4, Ljava/lang/StringBuilder;

    invoke-direct {v4}, Ljava/lang/StringBuilder;-><init>()V

    invoke-virtual {v4, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    const-string p1, "},\r\n"

    invoke-virtual {v4, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v4}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object p1

    goto :goto_3

    .line 176
    :cond_8
    new-instance v4, Ljava/lang/StringBuilder;

    invoke-direct {v4}, Ljava/lang/StringBuilder;-><init>()V

    invoke-virtual {v4, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    const-string p1, "}\r\n"

    invoke-virtual {v4, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v4}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object p1

    :goto_3
    add-int/lit8 v2, v2, 0x1

    goto/16 :goto_1

    .line 177
    :cond_9
    new-instance v1, Ljava/lang/StringBuilder;

    invoke-direct {v1}, Ljava/lang/StringBuilder;-><init>()V

    invoke-virtual {v1, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    const-string p1, "]"

    invoke-virtual {v1, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v1}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object p1

    .line 178
    new-instance v1, Les/lj$c;

    const-string v2, "200 OK"

    invoke-static {p1}, Les/ij;->c(Ljava/lang/String;)Ljava/io/InputStream;

    move-result-object v3

    invoke-direct {v1, p0, v2, v0, v3}, Les/lj$c;-><init>(Les/lj;Ljava/lang/String;Ljava/lang/String;Ljava/io/InputStream;)V

    const-string v2, "Content-Length"

    .line 179
    new-instance v3, Ljava/lang/StringBuilder;

    invoke-direct {v3}, Ljava/lang/StringBuilder;-><init>()V

    const-string v4, ""

    invoke-virtual {v3, v4}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    const-string v4, "utf-8"

    invoke-virtual {p1, v4}, Ljava/lang/String;->getBytes(Ljava/lang/String;)[B

    move-result-object p1

    array-length p1, p1

    invoke-virtual {v3, p1}, Ljava/lang/StringBuilder;->append(I)Ljava/lang/StringBuilder;

    invoke-virtual {v3}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object p1

    invoke-virtual {v1, v2, p1}, Les/lj$c;->a(Ljava/lang/String;Ljava/lang/String;)V
    :try_end_0
    .catch Ljava/lang/Exception; {:try_start_0 .. :try_end_0} :catch_0

    return-object v1

    :catch_0
    move-exception p1

    .line 180
    invoke-virtual {p1}, Ljava/lang/Exception;->printStackTrace()V

    .line 181
    new-instance v1, Les/lj$c;

    invoke-virtual {p1}, Ljava/lang/Exception;->toString()Ljava/lang/String;

    move-result-object p1

    const-string v2, "500 Internal Server Error"

    invoke-direct {v1, p0, v2, v0, p1}, Les/lj$c;-><init>(Les/lj;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;)V

    return-object v1
.end method

.method public a(Ljava/lang/String;Ljava/lang/String;Ljava/util/Properties;Ljava/util/Properties;Ljava/util/Properties;)Les/lj$c;
    .locals 9

    const-string v1, "/estrongs_filemgr_oauth_result"

    .line 103
    invoke-virtual {p1, v1}, Ljava/lang/String;->startsWith(Ljava/lang/String;)Z

    move-result v1

    if-eqz v1, :cond_1

    .line 104
    invoke-static {}, Lcom/estrongs/android/ui/view/CreateOAuthNetDisk;->B()Lcom/estrongs/android/ui/view/CreateOAuthNetDisk;

    move-result-object v0

    if-eqz v0, :cond_0

    .line 105
    invoke-virtual {v0, p4}, Lcom/estrongs/android/ui/view/CreateOAuthNetDisk;->a(Ljava/util/Properties;)V

    :cond_0
    const/4 v0, 0x0

    return-object v0

    :cond_1
    const-string v1, "POST"

    .line 106
    invoke-virtual {p2, v1}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z

    move-result v1

    const/4 v4, 0x0

    const-string v6, "Permission denied."

    const-string v7, "403 Forbidden"

    const-string v8, "text/plain"

    if-eqz v1, :cond_d

    .line 107
    invoke-static {}, Lcom/estrongs/android/util/o0;->d()Z

    move-result v1

    const-string v2, "400 Bad Request"

    const-string v3, ""

    if-nez v1, :cond_2

    .line 108
    new-instance v0, Les/lj$c;

    invoke-direct {v0, p0, v2, v8, v3}, Les/lj$c;-><init>(Les/lj;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;)V

    return-object v0

    :cond_2
    const-string v1, "x-es-client-ip"

    .line 109
    invoke-virtual {p3, v1, v3}, Ljava/util/Properties;->getProperty(Ljava/lang/String;Ljava/lang/String;)Ljava/lang/String;

    move-result-object v0

    .line 110
    invoke-static {v0}, Les/lj;->b(Ljava/lang/String;)Z

    move-result v0

    if-nez v0, :cond_3

    .line 111
    new-instance v0, Les/lj$c;

    invoke-direct {v0, p0, v7, v8, v6}, Les/lj$c;-><init>(Les/lj;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;)V

    return-object v0

    .line 112
    :cond_3
    new-instance v0, Ljava/lang/String;

    invoke-virtual {p0}, Les/lj;->a()[B

    move-result-object v1

    invoke-direct {v0, v1}, Ljava/lang/String;-><init>([B)V

    .line 113
    :try_start_0
    new-instance v1, Lorg/json/JSONObject;

    invoke-direct {v1, v0}, Lorg/json/JSONObject;-><init>(Ljava/lang/String;)V

    const-string v0, "command"

    .line 114
    invoke-virtual {v1, v0}, Lorg/json/JSONObject;->getString(Ljava/lang/String;)Ljava/lang/String;

    move-result-object v0

    const-string v5, "listApps"

    .line 115
    invoke-virtual {v0, v5}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z

    move-result v5

    if-eqz v5, :cond_4

    .line 116
    invoke-virtual {p0, v4}, Les/ij;->a(I)Les/lj$c;

    move-result-object v0

    return-object v0

    :cond_4
    const-string v4, "listAppsSystem"

    .line 117
    invoke-virtual {v0, v4}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z

    move-result v4

    if-eqz v4, :cond_5

    const/4 v0, 0x1

    .line 118
    invoke-virtual {p0, v0}, Les/ij;->a(I)Les/lj$c;

    move-result-object v0

    return-object v0

    :cond_5
    const-string v4, "listAppsPhone"

    .line 119
    invoke-virtual {v0, v4}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z

    move-result v4

    if-eqz v4, :cond_6

    const/4 v0, 0x2

    .line 120
    invoke-virtual {p0, v0}, Les/ij;->a(I)Les/lj$c;

    move-result-object v0

    return-object v0

    :cond_6
    const-string v4, "listAppsSdcard"

    .line 121
    invoke-virtual {v0, v4}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z

    move-result v4

    if-eqz v4, :cond_7

    const/4 v0, 0x3

    .line 122
    invoke-virtual {p0, v0}, Les/ij;->a(I)Les/lj$c;

    move-result-object v0

    return-object v0

    :cond_7
    const-string v4, "listAppsAll"

    .line 123
    invoke-virtual {v0, v4}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z

    move-result v4

    if-eqz v4, :cond_8

    const/4 v0, 0x4

    .line 124
    invoke-virtual {p0, v0}, Les/ij;->a(I)Les/lj$c;

    move-result-object v0

    return-object v0

    :cond_8
    const-string v4, "getAppThumbnail"

    .line 125
    invoke-virtual {v0, v4}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z

    move-result v4

    if-eqz v4, :cond_9

    .line 126
    invoke-virtual {p0, v1}, Les/ij;->a(Lorg/json/JSONObject;)Les/lj$c;

    move-result-object v0

    return-object v0

    :cond_9
    const-string v4, "appLaunch"

    .line 127
    invoke-virtual {v0, v4}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z

    move-result v4

    if-eqz v4, :cond_a

    .line 128
    invoke-virtual {p0, v1}, Les/ij;->c(Lorg/json/JSONObject;)Les/lj$c;

    move-result-object v0

    return-object v0

    :cond_a
    const-string v4, "appPull"

    .line 129
    invoke-virtual {v0, v4}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z

    move-result v4

    if-eqz v4, :cond_b

    .line 130
    invoke-virtual {p0, v1}, Les/ij;->d(Lorg/json/JSONObject;)Les/lj$c;

    move-result-object v0

    return-object v0

    :cond_b
    const-string v4, "getDeviceInfo"

    .line 131
    invoke-virtual {v0, v4}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z

    move-result v0

    if-eqz v0, :cond_c

    .line 132
    invoke-virtual {p0, v1}, Les/ij;->b(Lorg/json/JSONObject;)Les/lj$c;

    move-result-object v0

    return-object v0

    .line 133
    :cond_c
    new-instance v0, Les/lj$c;

    invoke-direct {v0, p0, v2, v8, v3}, Les/lj$c;-><init>(Les/lj;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;)V
    :try_end_0
    .catch Lorg/json/JSONException; {:try_start_0 .. :try_end_0} :catch_0

    return-object v0

    :catch_0
    move-exception v0

    .line 134
    new-instance v1, Les/lj$c;

    invoke-virtual {v0}, Lorg/json/JSONException;->toString()Ljava/lang/String;

    move-result-object v0

    invoke-direct {v1, p0, v2, v8, v0}, Les/lj$c;-><init>(Les/lj;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;)V

    return-object v1

    .line 135
    :cond_d
    invoke-static {p1}, Lcom/estrongs/android/util/h0;->a(Ljava/lang/String;)Ljava/lang/String;

    move-result-object v2

    if-nez v2, :cond_e

    .line 136
    new-instance v0, Les/lj$c;

    invoke-direct {v0, p0, v7, v8, v6}, Les/lj$c;-><init>(Les/lj;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;)V

    return-object v0

    .line 137
    :cond_e
    invoke-static {v2}, Lcom/estrongs/android/util/h0;->U(Ljava/lang/String;)I

    move-result v1

    if-nez v1, :cond_f

    move-object v1, p0

    move-object v3, p2

    move-object v4, p3

    move-object v5, p4

    move-object v6, p5

    .line 138
    invoke-super/range {v1 .. v6}, Les/lj;->a(Ljava/lang/String;Ljava/lang/String;Ljava/util/Properties;Ljava/util/Properties;Ljava/util/Properties;)Les/lj$c;

    move-result-object v0

    return-object v0

    :cond_f
    const-wide/16 v5, 0x0

    const-string v1, "range"

    .line 139
    invoke-virtual {p3, v1}, Ljava/util/Properties;->getProperty(Ljava/lang/String;)Ljava/lang/String;

    move-result-object v0

    if-eqz v0, :cond_11

    const-string v1, "bytes="

    .line 140
    invoke-virtual {v0, v1}, Ljava/lang/String;->startsWith(Ljava/lang/String;)Z

    move-result v1

    if-eqz v1, :cond_11

    const/4 v1, 0x6

    .line 141
    invoke-virtual {v0, v1}, Ljava/lang/String;->substring(I)Ljava/lang/String;

    move-result-object v0

    const/16 v1, 0x2d

    .line 142
    invoke-virtual {v0, v1}, Ljava/lang/String;->indexOf(I)I

    move-result v1

    if-lez v1, :cond_10

    .line 143
    invoke-virtual {v0, v4, v1}, Ljava/lang/String;->substring(II)Ljava/lang/String;

    move-result-object v0

    .line 144
    :cond_10
    :try_start_1
    invoke-static {v0}, Ljava/lang/Long;->parseLong(Ljava/lang/String;)J

    move-result-wide v0
    :try_end_1
    .catch Ljava/lang/NumberFormatException; {:try_start_1 .. :try_end_1} :catch_1

    move-wide v3, v0

    goto :goto_0

    :catch_1
    :cond_11
    move-wide v3, v5

    :goto_0
    const-wide/16 v5, 0x0

    move-object v1, p0

    .line 145
    invoke-direct/range {v1 .. v6}, Les/ij;->a(Ljava/lang/String;JJ)Les/lj$c;

    move-result-object v0

    return-object v0
.end method

.method public a(Lorg/json/JSONObject;)Les/lj$c;
    .locals 6

    const-string v0, "500 Internal Server Error"

    const-string v1, "text/plain"

    :try_start_0
    const-string v2, "appPackageName"

    .line 182
    invoke-virtual {p1, v2}, Lorg/json/JSONObject;->getString(Ljava/lang/String;)Ljava/lang/String;

    move-result-object p1

    if-nez p1, :cond_0

    .line 183
    new-instance p1, Les/lj$c;

    const-string v2, "400 Bad Request"

    const-string v3, "package not found: null"

    invoke-direct {p1, p0, v2, v1, v3}, Les/lj$c;-><init>(Les/lj;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;)V

    return-object p1

    .line 184
    :cond_0
    invoke-static {}, Lcom/estrongs/android/pop/FexApplication;->n()Lcom/estrongs/android/pop/FexApplication;

    move-result-object v2

    invoke-virtual {v2}, Landroid/app/Application;->getPackageManager()Landroid/content/pm/PackageManager;

    move-result-object v2

    invoke-static {v2, p1}, Lcom/estrongs/android/util/a;->a(Landroid/content/pm/PackageManager;Ljava/lang/String;)Landroid/graphics/Bitmap;

    move-result-object v2

    if-nez v2, :cond_1

    .line 185
    new-instance v2, Les/lj$c;

    new-instance v3, Ljava/lang/StringBuilder;

    invoke-direct {v3}, Ljava/lang/StringBuilder;-><init>()V

    const-string v4, "icon not found: "

    invoke-virtual {v3, v4}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v3, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v3}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object p1

    invoke-direct {v2, p0, v0, v1, p1}, Les/lj$c;-><init>(Les/lj;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;)V

    return-object v2

    .line 186
    :cond_1
    new-instance p1, Ljava/io/ByteArrayOutputStream;

    invoke-direct {p1}, Ljava/io/ByteArrayOutputStream;-><init>()V

    .line 187
    sget-object v3, Landroid/graphics/Bitmap$CompressFormat;->PNG:Landroid/graphics/Bitmap$CompressFormat;

    const/16 v4, 0x64

    invoke-virtual {v2, v3, v4, p1}, Landroid/graphics/Bitmap;->compress(Landroid/graphics/Bitmap$CompressFormat;ILjava/io/OutputStream;)Z

    .line 188
    invoke-virtual {p1}, Ljava/io/ByteArrayOutputStream;->toByteArray()[B

    move-result-object p1

    .line 189
    new-instance v2, Les/lj$c;

    const-string v3, "200 OK"

    const-string v4, "application/octet-stream"

    new-instance v5, Ljava/io/ByteArrayInputStream;

    invoke-direct {v5, p1}, Ljava/io/ByteArrayInputStream;-><init>([B)V

    invoke-direct {v2, p0, v3, v4, v5}, Les/lj$c;-><init>(Les/lj;Ljava/lang/String;Ljava/lang/String;Ljava/io/InputStream;)V

    const-string v3, "Content-Length"

    .line 190
    array-length p1, p1

    invoke-static {p1}, Ljava/lang/String;->valueOf(I)Ljava/lang/String;

    move-result-object p1

    invoke-virtual {v2, v3, p1}, Les/lj$c;->a(Ljava/lang/String;Ljava/lang/String;)V
    :try_end_0
    .catch Ljava/lang/Exception; {:try_start_0 .. :try_end_0} :catch_0

    return-object v2

    :catch_0
    move-exception p1

    .line 191
    new-instance v2, Les/lj$c;

    invoke-virtual {p1}, Ljava/lang/Exception;->toString()Ljava/lang/String;

    move-result-object p1

    invoke-direct {v2, p0, v0, v1, p1}, Les/lj$c;-><init>(Les/lj;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;)V

    return-object v2
.end method

.method a(Ljava/lang/String;Les/o80;)Ljava/lang/String;
    .locals 6

    const-string v0, "/"

    .line 15
    :try_start_0
    invoke-static {p1}, Lcom/estrongs/android/util/h0;->x(Ljava/lang/String;)Ljava/lang/String;

    move-result-object v1

    const/4 v2, 0x0

    const/4 v3, 0x0

    .line 16
    :goto_0
    iget-object v4, p0, Les/ij;->s:[Ljava/lang/String;

    array-length v4, v4

    if-ge v3, v4, :cond_1

    .line 17
    iget-object v4, p0, Les/ij;->s:[Ljava/lang/String;

    aget-object v4, v4, v3

    invoke-virtual {v1, v4}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z

    move-result v4

    if-eqz v4, :cond_0

    goto :goto_1

    :cond_0
    add-int/lit8 v3, v3, 0x1

    goto :goto_0

    .line 18
    :cond_1
    :goto_1
    iget-object v4, p0, Les/ij;->s:[Ljava/lang/String;

    array-length v4, v4

    if-lt v3, v4, :cond_2

    return-object p1

    .line 19
    :cond_2
    invoke-static {p1}, Lcom/estrongs/android/util/h0;->y(Ljava/lang/String;)Ljava/lang/String;

    move-result-object v3

    .line 20
    invoke-virtual {v3}, Ljava/lang/String;->length()I

    move-result v4

    invoke-virtual {v1}, Ljava/lang/String;->length()I

    move-result v5

    sub-int/2addr v4, v5

    invoke-virtual {v3, v2, v4}, Ljava/lang/String;->substring(II)Ljava/lang/String;

    move-result-object v3

    .line 21
    invoke-static {}, Lcom/estrongs/fs/f;->d()Lcom/estrongs/fs/f;

    move-result-object v4

    invoke-virtual {v4, p1}, Lcom/estrongs/fs/f;->c(Ljava/lang/String;)Z

    move-result v4

    if-eqz v4, :cond_3

    return-object p1

    .line 22
    :cond_3
    invoke-static {p1}, Lcom/estrongs/android/util/h0;->M(Ljava/lang/String;)Ljava/lang/String;

    move-result-object v4

    .line 23
    invoke-virtual {v4, v0}, Ljava/lang/String;->endsWith(Ljava/lang/String;)Z

    move-result v5

    if-nez v5, :cond_4

    .line 24
    new-instance v5, Ljava/lang/StringBuilder;

    invoke-direct {v5}, Ljava/lang/StringBuilder;-><init>()V

    invoke-virtual {v5, v4}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v5, v0}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v5}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v4

    .line 25
    :cond_4
    new-instance v0, Les/ij$a;

    invoke-direct {v0, p0, v1, v3}, Les/ij$a;-><init>(Les/ij;Ljava/lang/String;Ljava/lang/String;)V

    if-eqz p2, :cond_5

    .line 26
    invoke-interface {p2, v4, v0}, Les/o80;->a(Ljava/lang/String;Lcom/estrongs/fs/h;)Ljava/util/List;

    move-result-object p2

    goto :goto_2

    .line 27
    :cond_5
    invoke-static {}, Lcom/estrongs/fs/f;->d()Lcom/estrongs/fs/f;

    move-result-object p2

    new-instance v1, Lcom/estrongs/fs/m;

    invoke-direct {v1, v4}, Lcom/estrongs/fs/m;-><init>(Ljava/lang/String;)V

    invoke-virtual {p2, v1, v2, v0}, Lcom/estrongs/fs/f;->a(Lcom/estrongs/fs/g;ZLcom/estrongs/fs/h;)Ljava/util/List;

    move-result-object p2

    :goto_2
    if-eqz p2, :cond_8

    .line 28
    invoke-interface {p2}, Ljava/util/List;->size()I

    move-result v0

    if-lez v0, :cond_8

    const v0, 0x186a0

    .line 29
    invoke-interface {p2}, Ljava/util/List;->iterator()Ljava/util/Iterator;

    move-result-object v1

    const/4 v3, 0x0

    :goto_3
    invoke-interface {v1}, Ljava/util/Iterator;->hasNext()Z

    move-result v5

    if-eqz v5, :cond_7

    invoke-interface {v1}, Ljava/util/Iterator;->next()Ljava/lang/Object;

    move-result-object v5

    check-cast v5, Lcom/estrongs/fs/g;

    .line 30
    invoke-interface {v5}, Lcom/estrongs/fs/g;->getName()Ljava/lang/String;

    move-result-object v5

    invoke-virtual {v5}, Ljava/lang/String;->length()I

    move-result v5

    if-ge v5, v0, :cond_6

    move v2, v3

    move v0, v5

    :cond_6
    add-int/lit8 v3, v3, 0x1

    goto :goto_3

    .line 31
    :cond_7
    new-instance v0, Ljava/lang/StringBuilder;

    invoke-direct {v0}, Ljava/lang/StringBuilder;-><init>()V

    invoke-virtual {v0, v4}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-interface {p2, v2}, Ljava/util/List;->get(I)Ljava/lang/Object;

    move-result-object p2

    check-cast p2, Lcom/estrongs/fs/g;

    invoke-interface {p2}, Lcom/estrongs/fs/g;->getName()Ljava/lang/String;

    move-result-object p2

    invoke-virtual {v0, p2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v0}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object p1
    :try_end_0
    .catch Ljava/lang/Exception; {:try_start_0 .. :try_end_0} :catch_0

    :catch_0
    :cond_8
    return-object p1
.end method

.method public b(Lorg/json/JSONObject;)Les/lj$c;
    .locals 5

    const-string p1, "\", "

    const-string v0, "text/plain"

    :try_start_0
    const-string v1, "{"

    .line 1
    new-instance v2, Ljava/lang/StringBuilder;

    invoke-direct {v2}, Ljava/lang/StringBuilder;-><init>()V

    invoke-virtual {v2, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    const-string v1, "\"name\":\""

    invoke-virtual {v2, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    sget-object v1, Landroid/os/Build;->MODEL:Ljava/lang/String;

    invoke-virtual {v2, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v2, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v2}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v1

    .line 2
    new-instance v2, Ljava/lang/StringBuilder;

    invoke-direct {v2}, Ljava/lang/StringBuilder;-><init>()V

    invoke-virtual {v2, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    const-string v1, "\"ftpRoot\":\""

    invoke-virtual {v2, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-static {}, Lcom/estrongs/android/pop/l;->L1()Lcom/estrongs/android/pop/l;

    move-result-object v1

    invoke-virtual {v1}, Lcom/estrongs/android/pop/l;->G()Ljava/lang/String;

    move-result-object v1

    invoke-virtual {v2, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v2, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v2}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object p1

    .line 3
    new-instance v1, Ljava/lang/StringBuilder;

    invoke-direct {v1}, Ljava/lang/StringBuilder;-><init>()V

    invoke-virtual {v1, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    const-string p1, "\"ftpPort\":\""

    invoke-virtual {v1, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-static {}, Lcom/estrongs/android/pop/l;->L1()Lcom/estrongs/android/pop/l;

    move-result-object p1

    invoke-virtual {p1}, Lcom/estrongs/android/pop/l;->F()I

    move-result p1

    invoke-virtual {v1, p1}, Ljava/lang/StringBuilder;->append(I)Ljava/lang/StringBuilder;

    const-string p1, "\""

    invoke-virtual {v1, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v1}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object p1

    .line 4
    new-instance v1, Ljava/lang/StringBuilder;

    invoke-direct {v1}, Ljava/lang/StringBuilder;-><init>()V

    invoke-virtual {v1, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    const-string p1, "}"

    invoke-virtual {v1, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v1}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object p1

    .line 5
    new-instance v1, Les/lj$c;

    const-string v2, "200 OK"

    invoke-static {p1}, Les/ij;->c(Ljava/lang/String;)Ljava/io/InputStream;

    move-result-object v3

    invoke-direct {v1, p0, v2, v0, v3}, Les/lj$c;-><init>(Les/lj;Ljava/lang/String;Ljava/lang/String;Ljava/io/InputStream;)V

    const-string v2, "Content-Length"

    .line 6
    new-instance v3, Ljava/lang/StringBuilder;

    invoke-direct {v3}, Ljava/lang/StringBuilder;-><init>()V

    const-string v4, ""

    invoke-virtual {v3, v4}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    const-string v4, "utf-8"

    invoke-virtual {p1, v4}, Ljava/lang/String;->getBytes(Ljava/lang/String;)[B

    move-result-object p1

    array-length p1, p1

    invoke-virtual {v3, p1}, Ljava/lang/StringBuilder;->append(I)Ljava/lang/StringBuilder;

    invoke-virtual {v3}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object p1

    invoke-virtual {v1, v2, p1}, Les/lj$c;->a(Ljava/lang/String;Ljava/lang/String;)V
    :try_end_0
    .catch Ljava/lang/Exception; {:try_start_0 .. :try_end_0} :catch_0

    return-object v1

    :catch_0
    move-exception p1

    .line 7
    invoke-virtual {p1}, Ljava/lang/Exception;->printStackTrace()V

    .line 8
    new-instance v1, Les/lj$c;

    invoke-virtual {p1}, Ljava/lang/Exception;->toString()Ljava/lang/String;

    move-result-object p1

    const-string v2, "500 Internal Server Error"

    invoke-direct {v1, p0, v2, v0, p1}, Les/lj$c;-><init>(Les/lj;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;)V

    return-object v1
.end method

.method public c(Lorg/json/JSONObject;)Les/lj$c;
    .locals 6

    const-string v0, "500 Internal Server Error"

    const-string v1, "text/plain"

    :try_start_0
    const-string v2, "appPackageName"

    .line 4
    invoke-virtual {p1, v2}, Lorg/json/JSONObject;->getString(Ljava/lang/String;)Ljava/lang/String;

    move-result-object p1

    if-eqz p1, :cond_1

    .line 5
    new-instance v2, Landroid/content/Intent;

    invoke-direct {v2}, Landroid/content/Intent;-><init>()V

    .line 6
    invoke-static {}, Lcom/estrongs/android/pop/FexApplication;->n()Lcom/estrongs/android/pop/FexApplication;

    move-result-object v2

    invoke-virtual {v2}, Landroid/app/Application;->getPackageManager()Landroid/content/pm/PackageManager;

    move-result-object v2

    invoke-virtual {v2, p1}, Landroid/content/pm/PackageManager;->getLaunchIntentForPackage(Ljava/lang/String;)Landroid/content/Intent;

    move-result-object p1

    const/4 v2, 0x0

    if-eqz p1, :cond_0

    .line 7
    invoke-static {}, Lcom/estrongs/android/pop/FexApplication;->n()Lcom/estrongs/android/pop/FexApplication;

    move-result-object v3

    invoke-virtual {v3, p1}, Landroid/app/Application;->startActivity(Landroid/content/Intent;)V

    goto :goto_0

    :cond_0
    const/4 v2, -0x1

    :goto_0
    const-string p1, "{"

    .line 8
    new-instance v3, Ljava/lang/StringBuilder;

    invoke-direct {v3}, Ljava/lang/StringBuilder;-><init>()V

    invoke-virtual {v3, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    const-string p1, "\"result\":\""

    invoke-virtual {v3, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v3, v2}, Ljava/lang/StringBuilder;->append(I)Ljava/lang/StringBuilder;

    const-string p1, "\""

    invoke-virtual {v3, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v3}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object p1

    .line 9
    new-instance v2, Ljava/lang/StringBuilder;

    invoke-direct {v2}, Ljava/lang/StringBuilder;-><init>()V

    invoke-virtual {v2, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    const-string p1, "}"

    invoke-virtual {v2, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v2}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object p1

    .line 10
    new-instance v2, Les/lj$c;

    const-string v3, "200 OK"

    invoke-static {p1}, Les/ij;->c(Ljava/lang/String;)Ljava/io/InputStream;

    move-result-object v4

    invoke-direct {v2, p0, v3, v1, v4}, Les/lj$c;-><init>(Les/lj;Ljava/lang/String;Ljava/lang/String;Ljava/io/InputStream;)V

    const-string v3, "Content-Length"

    .line 11
    new-instance v4, Ljava/lang/StringBuilder;

    invoke-direct {v4}, Ljava/lang/StringBuilder;-><init>()V

    const-string v5, ""

    invoke-virtual {v4, v5}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    const-string v5, "utf-8"

    invoke-virtual {p1, v5}, Ljava/lang/String;->getBytes(Ljava/lang/String;)[B

    move-result-object p1

    array-length p1, p1

    invoke-virtual {v4, p1}, Ljava/lang/StringBuilder;->append(I)Ljava/lang/StringBuilder;

    invoke-virtual {v4}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object p1

    invoke-virtual {v2, v3, p1}, Les/lj$c;->a(Ljava/lang/String;Ljava/lang/String;)V

    return-object v2

    .line 12
    :cond_1
    new-instance v2, Les/lj$c;

    new-instance v3, Ljava/lang/StringBuilder;

    invoke-direct {v3}, Ljava/lang/StringBuilder;-><init>()V

    const-string v4, "not found the package "

    invoke-virtual {v3, v4}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v3, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v3}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object p1

    invoke-direct {v2, p0, v0, v1, p1}, Les/lj$c;-><init>(Les/lj;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;)V
    :try_end_0
    .catch Ljava/lang/Exception; {:try_start_0 .. :try_end_0} :catch_0

    return-object v2

    :catch_0
    move-exception p1

    .line 13
    invoke-virtual {p1}, Ljava/lang/Exception;->printStackTrace()V

    .line 14
    new-instance v2, Les/lj$c;

    invoke-virtual {p1}, Ljava/lang/Exception;->toString()Ljava/lang/String;

    move-result-object p1

    invoke-direct {v2, p0, v0, v1, p1}, Les/lj$c;-><init>(Les/lj;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;)V

    return-object v2
.end method

.method public d(Lorg/json/JSONObject;)Les/lj$c;
    .locals 7

    const-string v0, "text/plain"

    const-string v1, "500 Internal Server Error"

    :try_start_0
    const-string v2, "appPackageName"

    .line 2
    invoke-virtual {p1, v2}, Lorg/json/JSONObject;->getString(Ljava/lang/String;)Ljava/lang/String;

    move-result-object p1

    if-eqz p1, :cond_0

    .line 3
    invoke-static {}, Lcom/estrongs/android/pop/FexApplication;->n()Lcom/estrongs/android/pop/FexApplication;

    move-result-object v2

    invoke-virtual {v2}, Landroid/app/Application;->getPackageManager()Landroid/content/pm/PackageManager;

    move-result-object v2

    const/4 v3, 0x0

    invoke-virtual {v2, p1, v3}, Landroid/content/pm/PackageManager;->getApplicationInfo(Ljava/lang/String;I)Landroid/content/pm/ApplicationInfo;

    move-result-object v2

    .line 4
    new-instance v3, Ljava/io/File;

    iget-object v2, v2, Landroid/content/pm/ApplicationInfo;->sourceDir:Ljava/lang/String;

    invoke-direct {v3, v2}, Ljava/io/File;-><init>(Ljava/lang/String;)V

    .line 5
    invoke-virtual {v3}, Ljava/io/File;->exists()Z

    move-result v2

    if-eqz v2, :cond_0

    .line 6
    new-instance p1, Les/lj$c;

    const-string v2, "200 OK"

    const-string v4, "application/octet-stream"

    new-instance v5, Ljava/io/FileInputStream;

    invoke-direct {v5, v3}, Ljava/io/FileInputStream;-><init>(Ljava/io/File;)V

    invoke-direct {p1, p0, v2, v4, v5}, Les/lj$c;-><init>(Les/lj;Ljava/lang/String;Ljava/lang/String;Ljava/io/InputStream;)V

    const-string v2, "Content-Length"

    .line 7
    new-instance v4, Ljava/lang/StringBuilder;

    invoke-direct {v4}, Ljava/lang/StringBuilder;-><init>()V

    const-string v5, ""

    invoke-virtual {v4, v5}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v3}, Ljava/io/File;->length()J

    move-result-wide v5

    invoke-virtual {v4, v5, v6}, Ljava/lang/StringBuilder;->append(J)Ljava/lang/StringBuilder;

    invoke-virtual {v4}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v3

    invoke-virtual {p1, v2, v3}, Les/lj$c;->a(Ljava/lang/String;Ljava/lang/String;)V

    return-object p1

    .line 8
    :cond_0
    new-instance v2, Les/lj$c;

    new-instance v3, Ljava/lang/StringBuilder;

    invoke-direct {v3}, Ljava/lang/StringBuilder;-><init>()V

    const-string v4, "not found the package "

    invoke-virtual {v3, v4}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v3, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v3}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object p1

    invoke-direct {v2, p0, v1, v0, p1}, Les/lj$c;-><init>(Les/lj;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;)V
    :try_end_0
    .catch Ljava/lang/Exception; {:try_start_0 .. :try_end_0} :catch_0

    return-object v2

    :catch_0
    move-exception p1

    .line 9
    invoke-virtual {p1}, Ljava/lang/Exception;->printStackTrace()V

    .line 10
    new-instance v2, Les/lj$c;

    invoke-virtual {p1}, Ljava/lang/Exception;->toString()Ljava/lang/String;

    move-result-object p1

    invoke-direct {v2, p0, v1, v0, p1}, Les/lj$c;-><init>(Les/lj;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;)V

    return-object v2
.end method

.method public d()Z
    .locals 1

    .line 1
    iget-object v0, p0, Les/lj;->l:Ljava/lang/Thread;

    invoke-virtual {v0}, Ljava/lang/Thread;->isAlive()Z

    move-result v0

    return v0
.end method
